<extend name="Public:index" />
<block name="main-crumb">
    <li class="active">角色列表</li>
</block>
<block name="main-content">
    <div class="container-fluid">
        <div class="row">
            <div class="col-12">
                <div class="card">
                    <div class="card-body">
                        <form class="form-inline definewidth m20" action="{:U('Role/index')}" method="post">
                            <table class="table table-bordered table-hover definewidth m10">
                                <tr>
                                    <th>ID</th>
                                    <th>角色名</th>
                                    <th>是否禁用</th>
                                    <th>操作时间</th>
                                    <th>管理操作</th>
                                </tr>
                                <volist name="rolelist" id="mlist">
                                    <tr>

                                        <td>{$mlist[roleid]}</td>
                                        <td>{$mlist[rolename]}</td>
                                        <td>
                                            <if condition="$mlist[isforbidden] eq 1">
                                                禁用
                                                <else />
                                                启用
                                            </if>
                                        </td>
                                        <td>{$mlist[updatedatetime]}</td>
                                        <td>
                                            <if condition="$mlist[is_set] eq 1 ">
                                                <a href="__APP__/web/role/roleCode?roleid={$mlist[roleid]}&rolename={$mlist[rolename]}">设置控制权限</a>&nbsp;&nbsp;|
                                            </if>
                                            <if condition="$mlist[is_set] eq 1 ">
                                                <a href="__APP__/web/role/rolemeun?roleid={$mlist[roleid]}&rolename={$mlist[rolename]}">设置栏目权限</a>&nbsp;&nbsp;|
                                            </if>

                                     

                                            &nbsp;&nbsp;
                                            <a href="__APP__/web/role/edit?id={$mlist[roleid]}">编辑</a>&nbsp;&nbsp;
                                            |&nbsp;&nbsp;
                                            <a href="javascript:if(confirm('确认删除？'))location='__APP__/web/role/deletes?id={$mlist[roleid]}'">删除</a>

                                        </td>
                                    </tr>
                                </volist>
                                <tr>
                                    <td style="text-align:center" colspan="1"></td>
                                    <td style="text-align:left" colspan="1"> <a href="__APP__/web/role/add">添加角色</a></td>
                                    <td style="text-align:center" colspan="4" id="pages">{$page}</td>
                                </tr>
                            </table>
                        </form>
                    </div>
                </div>
            </div>
        </div>
    </div>
</block>